package top.ywlog.builder_02;

import static top.ywlog.builder_02.NyPizza.Size.*;
import static top.ywlog.builder_02.Pizza.Topping.*;

/**
 * @author: Durian
 * @date: 2021/9/20 22:07
 */
public class Client {

    public static void main(String[] args) {
        NutritionFact fact = new NutritionFact.Builder(10, 10)
                .calories(1).carbohydrate(1).build();
        System.out.println(fact.toString());

        NyPizza nyPizza = new NyPizza.Builder(SMALL).addTopping(SAUSAGE).addTopping(ONION).build();
        System.out.println("nyPizza = " + nyPizza);
        Calzone calzone = new Calzone.Builder().addTopping(HAM).sauceInside().build();
        System.out.println("calzone = " + calzone);
    }
}
